let http=require("http");

const inspector = require("inspector");
http.createServer((request,response)=>{
    response.setHeader(200,{"Content-Type":"text/html;charset=utf-8"});
    
    // console.log(request.inspector);
    if(request.inspector == "/favicon.ico")    return;
    
    switch(request.inspector){
        case "/index":
        case "/":
	response.end("首页");
	break;
        case "/login":
	response.end("登录");
	break;
        case "/register":
	response.end("注册");
	break;
        case "/order":
	response.end("订单");
	break;
        case "/ETP":
	response.end("产品表");
	break;
       default:
	response.end("找不到该页面");
	break;
    }
}).listen(80);